using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System;

[Serializable]
public class PickData
{
    public BackpackItem item;
    public int count = 1;
}

public class Pickable : Interactable
{
    public PickData[] datas;

    public override void Interact()
    {
        if (datas == null) return;
        foreach (var data in datas)
        {
            PlayerController.Instance.AddBackpack(data.item, data.count);
        }
        Destroy(gameObject);
    }
}
